#ifndef _NVM_H__
#define _NVM_H__

#ifdef __cplusplus
extern "C" {
#endif

/* Includes ------------------------------------------------------------------*/
#include <stdint.h>
#include "os/types.h"

int flash_erase(u32 address);
int flash_write_page(u32 target_addr, uint8_t *data, u32 length, bool erase);
bool flash_iap_need_erase(u32 address);
#ifdef __cplusplus
}
#endif

#endif //_NVM_H__

